#include "figurecontainer.h"
#include "circle.h"
#include "triangle.h"
#include "rectangle.h"

Figure* Figure::makeFigure(typeFigure type, std::vector<double> &data)
{
    switch(type){
    case circle:
        return new Circle(data);
        break;
    case triangle:
        return new Triangle(data);
        break;
    case rectangle:
        return new Rectangle(data);
        break;
    }
    return nullptr;
}
